using System;
using System.Collections.Generic;
using System.Text;
using Castle.ActiveRecord;
using NHibernate.Expression;

namespace WOODIFramework.Model
{
    [ActiveRecord("Label")]
    public class Label : PageItem
    {
        #region Fields

        private Guid _labelId;
        private string _name;
        private string _tooltip;
        private string _labelText;

        #endregion

        #region Properties

        [JoinedKey("labelID")]
        public Guid LabelId
        {
            get { return _labelId; }
            set { _labelId = value; }
        }

        [Property]
        public string LabelText
        {
            get { return _labelText; }
            set { _labelText = value; }
        }

        [Property]
        public string Tooltip
        {
            get { return _tooltip; }
            set { _tooltip = value; }
        }

        #endregion

        #region Constructors

        private Label()
        {
            this.Id = Guid.NewGuid();
            this.LabelId = this.Id;
        }


        private Label(string Name)
        {
            this.Id = Guid.NewGuid();
            this.LabelId = this.Id;
            this.Name = Name;
        }

        private Label(string Name, string LabelText)
        {
            this.Id = Guid.NewGuid();
            this.LabelId = this.Id;
            this.Name = Name;
            this.LabelText = LabelText;
        }

        #endregion

        #region Public Methods

        #region Public Static Methods

        public static Label CreateLabel()
        {
            return new Label();
        }

        public static Label CreateLabel(string Name)
        {
            return new Label(Name);
        }

        public static Label CreateLabel(string Name, string LabelText)
        {
            return new Label(Name, LabelText);
        }

        #endregion

        #endregion


    }
}
